

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Code Reviews with Phabricator &mdash; LLVM 3.2 documentation</title>
    
    <link rel="stylesheet" href="_static/llvm-theme.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '',
        VERSION:     '3.2',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="top" title="LLVM 3.2 documentation" href="index.html" />
    <link rel="up" title="User Guides" href="userguides.html" />
    <link rel="next" title="Programming Documentation" href="programming.html" />
    <link rel="prev" title="Sphinx Quickstart Template" href="SphinxQuickstartTemplate.html" />
<style type="text/css">
  table.right { float: right; margin-left: 20px; }
  table.right td { border: 1px solid #ccc; }
</style>

  </head>
  <body>
<div class="logo">
  <a href="index.html">
    <img src="_static/logo.png"
         alt="LLVM Logo" width="250" height="88"/></a>
</div>

    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="programming.html" title="Programming Documentation"
             accesskey="N">next</a> |</li>
        <li class="right" >
          <a href="SphinxQuickstartTemplate.html" title="Sphinx Quickstart Template"
             accesskey="P">previous</a> |</li>
  <li><a href="http://llvm.org/">LLVM Home</a>&nbsp;|&nbsp;</li>
  <li><a href="index.html">Documentation</a>&raquo;</li>

          <li><a href="userguides.html" accesskey="U">User Guides</a> &raquo;</li> 
      </ul>
    </div>

      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h3><a href="index.html">Table Of Contents</a></h3>
  <ul>
<li><a class="reference internal" href="#">Code Reviews with Phabricator</a><ul>
<li><a class="reference internal" href="#sign-up">Sign up</a></li>
<li><a class="reference internal" href="#requesting-a-review-via-the-command-line">Requesting a review via the command line</a></li>
<li><a class="reference internal" href="#requesting-a-review-via-the-web-interface">Requesting a review via the web interface</a></li>
<li><a class="reference internal" href="#reviewing-code-with-phabricator">Reviewing code with Phabricator</a></li>
<li><a class="reference internal" href="#status">Status</a></li>
</ul>
</li>
</ul>

  <h4>Previous topic</h4>
  <p class="topless"><a href="SphinxQuickstartTemplate.html"
                        title="previous chapter">Sphinx Quickstart Template</a></p>
  <h4>Next topic</h4>
  <p class="topless"><a href="programming.html"
                        title="next chapter">Programming Documentation</a></p>
  <h3>This Page</h3>
  <ul class="this-page-menu">
    <li><a href="_sources/Phabricator.txt"
           rel="nofollow">Show Source</a></li>
  </ul>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="search.html" method="get">
      <input type="text" name="q" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <div class="section" id="code-reviews-with-phabricator">
<h1>Code Reviews with Phabricator<a class="headerlink" href="#code-reviews-with-phabricator" title="Permalink to this headline">¶</a></h1>
<div class="contents local topic" id="contents">
<ul class="simple">
<li><a class="reference internal" href="#sign-up" id="id1">Sign up</a></li>
<li><a class="reference internal" href="#requesting-a-review-via-the-command-line" id="id2">Requesting a review via the command line</a></li>
<li><a class="reference internal" href="#requesting-a-review-via-the-web-interface" id="id3">Requesting a review via the web interface</a></li>
<li><a class="reference internal" href="#reviewing-code-with-phabricator" id="id4">Reviewing code with Phabricator</a></li>
<li><a class="reference internal" href="#status" id="id5">Status</a></li>
</ul>
</div>
<p>If you prefer to use a web user interface for code reviews,
you can now submit your patches for Clang and LLVM at
<a class="reference external" href="http://llvm-reviews.chandlerc.com">LLVM&#8217;s Phabricator</a>.</p>
<div class="section" id="sign-up">
<h2><a class="toc-backref" href="#id1">Sign up</a><a class="headerlink" href="#sign-up" title="Permalink to this headline">¶</a></h2>
<p>There are two options to get an account on Phabricator. You can sign up
immediately with one of the supported OAuth account types if you&#8217;re comfortable
with OAuth, but you can also email <a class="reference external" href="mailto:chandlerc&#37;&#52;&#48;gmail&#46;com">chandlerc<span>&#64;</span>gmail<span>&#46;</span>com</a> to request an account to
be created manually without using OAuth. We&#8217;re working to get support in
Phabricator to directly create new accounts, but currently this is a manual
process.</p>
<p>Note that if you use your Subversion user name as Phabricator user name,
Phabricator will automatically connect your submits to your Phabricator user in
the <a class="reference external" href="http://llvm-reviews.chandlerc.com/diffusion/">Code Repository Browser</a>.</p>
</div>
<div class="section" id="requesting-a-review-via-the-command-line">
<h2><a class="toc-backref" href="#id2">Requesting a review via the command line</a><a class="headerlink" href="#requesting-a-review-via-the-command-line" title="Permalink to this headline">¶</a></h2>
<p>Phabricator has a tool called <em>Arcanist</em> to upload patches from
the command line. To get you set up, follow the
<a class="reference external" href="http://www.phabricator.com/docs/phabricator/article/Arcanist_Quick_Start.html">Arcanist Quick Start</a> instructions.</p>
<p>You can learn more about how to use arc to interact with
Phabricator in the <a class="reference external" href="http://www.phabricator.com/docs/phabricator/article/Arcanist_User_Guide.html">Arcanist User Guide</a>.</p>
</div>
<div class="section" id="requesting-a-review-via-the-web-interface">
<h2><a class="toc-backref" href="#id3">Requesting a review via the web interface</a><a class="headerlink" href="#requesting-a-review-via-the-web-interface" title="Permalink to this headline">¶</a></h2>
<p>The tool to create and review patches in Phabricator is called
<em>Differential</em>.</p>
<p>Note that you can upload patches created through various diff tools,
including git and svn. To make reviews easier, please always include
<strong>as much context as possible</strong> with your diff! Don&#8217;t worry, Phabricator
will automatically send a diff with a smaller context in the review
email, but having the full file in the web interface will help the
reviewer understand your code.</p>
<p>To get a full diff, use one of the following commands (or just use Arcanist
to upload your patch):</p>
<ul class="simple">
<li><tt class="docutils literal"><span class="pre">git</span> <span class="pre">diff</span> <span class="pre">-U999999</span> <span class="pre">other-branch</span></tt></li>
<li><tt class="docutils literal"><span class="pre">svn</span> <span class="pre">diff</span> <span class="pre">--diff-cmd=diff</span> <span class="pre">-x</span> <span class="pre">-U999999</span></tt></li>
</ul>
<p>To upload a new patch:</p>
<ul class="simple">
<li>Click <em>Differential</em>.</li>
<li>Click <em>Create Revision</em>.</li>
<li>Paste the text diff or upload the patch file.
Note that TODO</li>
<li>Leave the drop down on <em>Create a new Revision...</em> and click <em>Continue</em>.</li>
<li>Enter a descriptive title and summary; add reviewers and mailing
lists that you want to be included in the review. If your patch is
for LLVM, cc llvm-commits; if your patch is for Clang, cc cfe-commits.</li>
<li>Click <em>Save</em>.</li>
</ul>
<p>To submit an updated patch:</p>
<ul class="simple">
<li>Click <em>Differential</em>.</li>
<li>Click <em>Create Revision</em>.</li>
<li>Paste the updated diff.</li>
<li>Select the review you want to from the <em>Attach To</em> dropdown and click
<em>Continue</em>.</li>
<li>Click <em>Save</em>.</li>
</ul>
</div>
<div class="section" id="reviewing-code-with-phabricator">
<h2><a class="toc-backref" href="#id4">Reviewing code with Phabricator</a><a class="headerlink" href="#reviewing-code-with-phabricator" title="Permalink to this headline">¶</a></h2>
<p>Phabricator allows you to add inline comments as well as overall comments
to a revision. To add an inline comment, select the lines of code you want
to comment on by clicking and dragging the line numbers in the diff pane.</p>
<p>You can add overall comments or submit your comments at the bottom of the page.</p>
<p>Phabricator has many useful features, for example allowing you to select
diffs between different versions of the patch as it was reviewed in the
<em>Revision Update History</em>. Most features are self descriptive - explore, and
if you have a question, drop by on #llvm in IRC to get help.</p>
</div>
<div class="section" id="status">
<h2><a class="toc-backref" href="#id5">Status</a><a class="headerlink" href="#status" title="Permalink to this headline">¶</a></h2>
<p>Currently, we&#8217;re testing Phabricator for use with Clang/LLVM. Please let us
know whether you like it and what could be improved!</p>
</div>
</div>


          </div>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             >index</a></li>
        <li class="right" >
          <a href="programming.html" title="Programming Documentation"
             >next</a> |</li>
        <li class="right" >
          <a href="SphinxQuickstartTemplate.html" title="Sphinx Quickstart Template"
             >previous</a> |</li>
  <li><a href="http://llvm.org/">LLVM Home</a>&nbsp;|&nbsp;</li>
  <li><a href="index.html">Documentation</a>&raquo;</li>

          <li><a href="userguides.html" >User Guides</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
        &copy; Copyright 2012, LLVM Project.
      Last updated on 2012-12-21.
      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
    </div>
  </body>
</html>